{% extends "bvblogapp/base.html" %}
{% block pageName %}BioVenTurist - Search companies{% endblock %}

{% block queryScript %}

<!--CSS file (default YUI Sam Skin) -->

<!-- Individual YUI CSS files --> 
<link rel="stylesheet" type="text/css" href="http://yui.yahooapis.com/2.8.0r4/build/paginator/assets/skins/sam/paginator.css"> 
<link rel="stylesheet" type="text/css" href="http://yui.yahooapis.com/2.8.0r4/build/datatable/assets/skins/sam/datatable.css"> 
<!-- Individual YUI JS files --> 
<script type="text/javascript" src="http://yui.yahooapis.com/2.8.0r4/build/yahoo/yahoo-min.js"></script> 
<script type="text/javascript" src="http://yui.yahooapis.com/2.8.0r4/build/event/event-min.js"></script> 
<script type="text/javascript" src="http://yui.yahooapis.com/2.8.0r4/build/connection/connection-min.js"></script> 
<script type="text/javascript" src="http://yui.yahooapis.com/2.8.0r4/build/datasource/datasource-min.js"></script> 
<script type="text/javascript" src="http://yui.yahooapis.com/2.8.0r4/build/dom/dom-min.js"></script> 
<script type="text/javascript" src="http://yui.yahooapis.com/2.8.0r4/build/element/element-min.js"></script> 
<script type="text/javascript" src="http://yui.yahooapis.com/2.8.0r4/build/paginator/paginator-min.js"></script> 
<script type="text/javascript" src="http://yui.yahooapis.com/2.8.0r4/build/datatable/datatable-min.js"></script> 
<script type="text/javascript" src="http://yui.yahooapis.com/2.8.0r4/build/get/get-min.js"></script> 
<script type="text/javascript" src="http://yui.yahooapis.com/2.8.0r4/build/json/json-min.js"></script> 
<script type="text/javascript" src="http://yui.yahooapis.com/2.8.0r4/build/selector/selector-min.js"></script>


<link type="text/css" rel="stylesheet" href="/bvsearchapp/static/css/bvsearchapp.css" />

<!-- jQuery packed from Google CDN -->
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>

<!-- Freebase controls -->
<link type="text/css" rel="stylesheet" href="/static/css/freebase-controls.css" />
<script src="/static/js/freebase.suggest.js" type="text/javascript"></script>
<!-- Curvy corners jQuery plugin -->
<script type="text/javascript" src="/static/js/jquery.curvycorners.packed.js"></script>
<!-- Facebox jQuery plugin -->
<link href="/bvsearchapp/static/js/facebox.css" media="screen" rel="stylesheet" type="text/css"/>
<script src="/bvsearchapp/static/js/facebox.js" type="text/javascript"></script>

<!-- Load ListFormatter and CompanyNameFormatter -->
<script type="text/javascript" src="/bvsearchapp/static/js/formatters.js"></script>
<script type="text/javascript">
function load_info(){return true};

jQuery(document).ready(function(){
	jQuery('div.w100p').html('<h1>Hi!</h1>')
	});
</script>

{% endblock %}

{% block container %}
<div id="bvsearchapp">

<!-- begin: Search block -->
<div class="container" style="width:889px;">
    <div class="c" style="background:#F1F1F1;padding:16px; border: 2px solid #999;">
        <div id="filters_div">
            <span class="large">Find companies by</span>
            <select name="filter_type" class="first filter_type">
                <option value="name">Company name</option>
                <option value="has_area_of_expertise">Technology Focus</option>
                <option value="products">Products</option>
                <option value="has_develops_treatments_for_disease">Medical focus</option>
            </select>
            <input type="text" size="10" name="filter_query" class="filter_query" />
            <input type="button" class="filter_add" value="+"/>
            <input type="button" class="filter_run" name="filter" value="Search" />
            <img src="/static/img/ajax-loader.gif" style="margin-left: .5em; display: none; position: relative; top: 3px;" id="img_loading" alt="Loading..." /><br />
        </div>
    </div>
</div>
<!-- end: Search block -->

<!-- begin: Count of results -->
<p class="results_count">Showing <span id="records_index"></span> <strong id="total_records">0</strong> companies <span id="filters"></span></p>
<!-- end: Count of results -->

<div class="w100p" style="margin-bottom: 1em;">
    <table border="0" cellpadding="0" cellspacing="0" style="width: 100%; margin-top: 1em;" summary="Search">
        <tr valign="middle">
            <td width="50%">
                <a id="id_add_rows" class="u" href="#">Add</a>
                <select id="id_row_to_add" name="row_to_add" style="display: none;"></select>
                <input type="button" name="button_row_add" id="id_button_row_add" value="Add"  style="display: none;"/>
                <span> or </span>
                <a id="id_rm_rows" class="u" href="#">Del</a>
                <select id="id_row_to_rm" name="row_to_rm" style="display: none;"></select>
                <input type="button" name="button_row_rm" id="id_button_row_rm" value="Del"  style="display: none;"/>
                <span> columns?</span>
            </td>
            <td width="50%" class="right">
                <input type="button" name="save" value="Save {% if not request.user.username %}*{% endif %}" id="id_button_save" {% if not request.user.username %}disabled="disabled" {% endif %}/>
                <input type="button" id="id_share_button" name="share" value="Share" />
                <input type="button" name="export" value="Export" id="id_button_export" />
                {% if not request.user.username %}
                <p style="font-size: x-small; color: #999; text-align: right;">* You must  be logged in.</p>
                {% endif %}
           </td>
        </tr>
    </table>
</div>

<div id="results"></div>
<div id="paginated"></div>

<form name="widget" id="widget" method="post" style="display: none;" action="{% url companies_widget %}">
    <textarea name="text" id="input_widget" rows="30" cols="100"></textarea>
</form>

{% if request.user.username %}
<form name="save_as_analysis" id="post_to_analysis" method="post" style="display: none;" action="{% url blog_create request.user.username %}">
    <textarea name="text" id="text" rows="30" cols="100"></textarea>
    <input type="hidden" name="external_data" value="True" /> <!-- If this variable in POST, then new analysis will be filled with POST['text'] data. -->
</form>
{% endif %}

</div>
{% endblock %}
